export interface QueryInt {
    id:number,
    authority:string
}
interface ListInt {
    name:string,
    roleId:number,
    viewRole?:string,
    roleList?:ListInt[]
}

export class InitData {
    id:number = 0;
    authorityIds:number[] = []
    list:ListInt[] = []
    treeRef:any
    constructor(id:number,authority:string){//new的时候可传值
        this.id = id,
        this.authorityIds = authority.split(',').map(v=>+v)//先将字符串转成数组，后将字符转数字
    }
}